package com.cloudkinto.service.user;

import com.baomidou.mybatisplus.extension.service.IService;
import com.cloudkinto.common.web.SingleResult;
import com.cloudkinto.entity.*;
import com.cloudkinto.service.user.wxvo.WxTempMsgEntity;
import com.cloudkinto.service.user.wxvo.WxTokenByCodeEntity;

import java.util.Map;

/**
 * <p>
 * service接口
 * </p>
 *
 * @author zhangyy
 * @since 2020-10-10
 */
public interface WxUserService extends IService<WxUserDo> {

    //获取网页授权token
    WxTokenByCodeEntity getAccessTokenByCode(String code);

    //获取普通token
    String getAccessToken();

    WxUserDo getUserInfoCommonByToken( String openid);

    //获取getJSDKSign
    Map getJSDKSign(String url);

    //获取用户信息并保存
    WxUserDo getUserInfoByToken(String access_token, String openid, Long userId, Long companyId);

    String sendTemMsg(WxTempMsgEntity wxTempMsg, String toUser, String tempId);

    String sendTemMsg(WxTempMsgEntity wxTempMsg, String toUser, int type);

    //入库推送
    void orderInput(OrderInputDo orderInputDo);

    //fba头程推送
    void firstVessel(FirstVesselOrderDo firstVesselOrderDo);

    //退货推送
    void orderBack(OrderBackDo orderBackDo);

    //余额可用天数推送
    void sendAvailableBalanceTemMsg(CompanyAccountDo companyAccountDo, int remainDays);

}
